﻿using Dora.Orm.Core.Domain.Entities;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Text;

namespace Dora.Services.AdminUser.Entities
{
    /// <summary>
    /// 角色表实体对象
    /// </summary>
    [SugarTable("role")]
    public class RoleEntity : Entity<Guid>
    {
        #region model


        /// <summary>
        /// 系统Id
        /// </summary>
        public int SystemId { get; set; }

        /// <summary>
        /// 系统Key
        /// </summary>
        public string SystemKey { get; set; }

        /// <summary>
        /// 组织机构Id
        /// </summary>
        public int OrgId { get; set; }

        /// <summary>
        /// 角色名称
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 角色编号;唯一，可修改，可用于标识特殊的角色，如EB超级管理员
        /// </summary>
        public string RoleNO { get; set; }

        /// <summary>
        /// 组织机构类型 0所有组织机构通用 1大社 2分社 3门店 4直属门店
        /// </summary>
        public int OrgType { get; set; }

        /// <summary>
        /// 排序;倒序
        /// </summary>
        public int Sort { get; set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string Remark { get; set; }

        /// <summary>
        /// 来源角色Id
        /// </summary>
        public Guid SourceRoleId { get; set; }

        /// <summary>
        /// 是否默认角色 0-默认；1-预置
        /// </summary>
        public short RoleType { get; set; }

        /// <summary>
        /// 是否启用;停用后，拥有角色的用户不能再有这个角色对应的权限
        /// </summary>
        public short IsEnabled { get; set; }

        /// <summary>
        /// 是否删除
        /// </summary>
        public short IsDeleted { get; set; }

        /// <summary>
        /// 创建人Id
        /// </summary>
        public Guid? CreatedUserId { get; set; }

        /// <summary>
        /// 创建人
        /// </summary>
        public string CreatedUserName { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreatedTime { get; set; }

        /// <summary>
        /// 更新人Id
        /// </summary>
        public Guid? UpdatedUserId { get; set; }

        /// <summary>
        /// 更新人
        /// </summary>
        public string UpdatedUserName { get; set; }

        /// <summary>
        /// 更新时间
        /// </summary>
        public DateTime? UpdatedTime { get; set; }

        #endregion
        #region extend
        #endregion
    }
}
